import {createRouter, createWebHistory, RouteRecordRaw} from 'vue-router'

const routes:Array<RouteRecordRaw> = [
    {
        path:"/",
        component:()=> import('../views/Test.vue')
    },
    // {
    //     path:"/Login",
    //     component:()=> import('../views/Login.vue')
    // },
    // {
    //     path:"/businessInfo",
    //     component:()=> import('../views/Businessinfo.vue')
    // },
    // {
    //     path:"/businessList",
    //     component:()=> import('../views/BusinessList.vue')
    // },
    // {
    //     path:"/historyOrders",
    //     component:()=> import('../views/OrderList.vue')
    // },
    // {
    //     path:"/register",
    //     component:()=> import('../views/Register.vue')
    // },
    // {
    //     path:"/orders",
    //     component:()=> import('../views/Orders.vue')
    // },
    // {
    //     path:"/userAddress",
    //     component:()=> import('../views/UserAdress.vue')
    // },
    // {
    //     path:"/payment",
    //     component:()=> import('../views/Payment.vue')
    // },
    // {
    //     path:"/addUserAddress",
    //     component:()=> import('../views/AddUserAddress.vue')
    // },
    // {
    //     path:"/editUserAddress",
    //     component:()=> import('../views/EditUserAdress.vue')
    // },
    {
        path:"/test",
        component:()=> import('../views/Test.vue')
    },
]

const router = createRouter({
    history:createWebHistory(),
    routes
})

export default router
//把上面创建的router 传出去
//然后需要在main.ts注册一下这个router, 因为它相当于一个插件